package com.sghd.pojo.fight.game;

import java.util.HashMap;
import java.util.Map;

/**
 * @author frank
 * @date 2018-10-18 16:50
 * @desc
 **/
public enum ChessType {
    CT_RED("红"),
    CT_BLUE("蓝"),
    CT_GREEN("绿"),
    CT_PURPLE("紫"),
    CT_LIGHTNING("电"),
    CT_YELLOW("黄");

    private String show;
    static Map<String, ChessType> values = new HashMap<>();
    static {
        for (ChessType chessType : ChessType.values()) {
            values.put(chessType.getShow(), chessType);
        }
    }
    public static ChessType valueOfShow(String name){
        return values.get(name);
    }
    private ChessType(String show) {
        this.show = show;
    }

    public String getShow() {
        return show;
    }
}
